package com.qj.yantaishan.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.IService;
import org.springframework.beans.factory.annotation.Autowired;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.context.annotation.Primary;
import org.springframework.stereotype.Service;
import com.qj.yantaishan.mapper.CompanyMapper;
import com.qj.yantaishan.domain.Company;
import com.qj.yantaishan.service.ICompanyService;
import com.qj.yantaishan.common.core.text.Convert;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author qihe
 * @date 2022-07-22
 */
@Service
@Primary
public class CompanyServiceImpl    extends ServiceImpl<CompanyMapper, Company>  implements ICompanyService
{
    @Autowired
    private CompanyMapper companyMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param companyId 【请填写功能名称】主键
     * @return 【请填写功能名称】
     */
    @Override
    public Company selectCompanyByCompanyId(Integer companyId)
    {
        return companyMapper.selectCompanyByCompanyId(companyId);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param company 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<Company> selectCompanyList(Company company)
    {
        return companyMapper.selectCompanyList(company);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param company 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertCompany(Company company)
    {
        return companyMapper.insertCompany(company);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param company 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateCompany(Company company)
    {
        return companyMapper.updateCompany(company);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param companyIds 需要删除的【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteCompanyByCompanyIds(String companyIds)
    {
        return companyMapper.deleteCompanyByCompanyIds(Convert.toStrArray(companyIds));
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param companyId 【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteCompanyByCompanyId(Integer companyId)
    {
        return companyMapper.deleteCompanyByCompanyId(companyId);
    }
}
